
const macBtn = document.createElement('button');
macBtn.textContent = '点击体验 macOS 交互';
document.body.appendChild(macBtn);

macBtn.addEventListener('click', () => {
    alert('你触发了 JavaScript 交互！这是 macOS 环境下的效果~');
});


const title = document.querySelector('h2');
title.addEventListener('mouseover', () => {
    title.style.color = '#FF3B30'; // 苹果风格红色
});

title.addEventListener('mouseout', () => {
    title.style.color = '#007AFF';
});